package com.eicas.controller;

import com.eicas.entity.UserDB;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.net.http.HttpRequest;

/**
 * @author: Administrator
 * @since: 2023/2/9 11:18
 * @description:
 */
@RestController
@RequestMapping("/home")
public class HomeController {

    @GetMapping
    public String homepage(){
        StringBuilder sb = new StringBuilder();
        // list user
        for (int i = 0; i < UserDB.userDB.size(); i++) {
            sb.append(UserDB.userDB.get(i).toString()+"\n");
        }
        return sb.toString();
    }
}
